package com.dhcc.bpm.modules.scf.service;
import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.service.IService;
import com.dhcc.bpm.modules.scf.dto.ScfSubjectBasicInfoDTO;
import com.dhcc.bpm.modules.scf.entity.ScfSubjectBasicInfo;
import com.dhcc.bpm.modules.scf.vo.ScfSubjectBasicInfoVO.ScfGetSubjectDetailsVO;
import com.dhcc.bpm.modules.scf.vo.ScfSubjectBasicInfoVO.ScfGetSubjectListVO;
import org.springframework.web.multipart.MultipartFile;

import java.io.IOException;
import java.util.List;


/**
 *  主体基本信息表服务类
 */
public interface IScfSubjectBasicInfoService extends IService<ScfSubjectBasicInfo> {


    /**
     * 自定义分页
     * @param page
     * @param scfSubjectBasicInfo
     * @return
     */
    IPage<ScfGetSubjectListVO> selectScfSubjectBasicInfoPage(IPage<ScfGetSubjectListVO> page, ScfSubjectBasicInfoDTO scfSubjectBasicInfo);

    /**
     * 自定义查询详情
     * @param scfSubjectBasicInfo
     * @return
     */
    ScfGetSubjectDetailsVO getDetails(ScfSubjectBasicInfoDTO scfSubjectBasicInfo);

    /**
     * 新增主体信息
     * @param scfSubjectBasicInfo
     * @return
     */
    Boolean saveSubjectBasic(ScfSubjectBasicInfoDTO scfSubjectBasicInfo) throws Exception;

    /**
     * 导入主体信息
     *
     * @param scfSubjectBasicInfos
     * @return
     */
    int bachSaveSubjectBasic(List<ScfSubjectBasicInfo> scfSubjectBasicInfos, String operatorId);

    /**
     * 更新主体信息
     *
     * @param scfSubjectBasicInfo
     * @return
     */
    Boolean updateSubjectBasic(ScfSubjectBasicInfoDTO scfSubjectBasicInfo);

    /**
     * 主体信息-批量导入
     * 当前用户ID
     *
     * @param file
     * @return
     */
    List<ScfSubjectBasicInfo> batchSaveSubjectBasic(String operatorId, MultipartFile file) throws IOException;

    Boolean deleteByIds( String[] ids );

}
